package com.ego.ware.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.ego.common.vo.PageVo;
import com.ego.ware.po.Purchase;
import com.ego.ware.po.PurchaseDetail;
import com.ego.ware.vo.PurchaseDetailSearchVo;
import com.ego.ware.vo.PurchaseDetailVo;
import com.ego.ware.vo.PurchaseMergeVo;

import java.util.List;

/**
 * @program: ego
 * @description 服务层
 * @author KamTang
 * @date 2022-11-13 13:30:29
 */
public interface PurchaseDetailService extends IService<PurchaseDetail> {
    /**
     * 搜索采购需求
     * @param search @see
     * @return 采购需求
     * @see PurchaseDetailSearchVo
     */
    PageVo<PurchaseDetailVo> search(PurchaseDetailSearchVo search);

    /**
     * 新增采购需求
     * @param purchaseDetailVo @see
     * @see PurchaseDetailVo
     */
    void save(PurchaseDetailVo purchaseDetailVo);

    /**
     * 根据id获取具体采购需求信息
     * @param id id
     * @return @see
     * @see PurchaseDetailVo
     */
    PurchaseDetailVo get(Long id);

    /**
     * 合并采购单
     * @param merge @see
     * @return 是否成功
     * @see PurchaseMergeVo
     */
    boolean merge(PurchaseMergeVo merge);
}

